export const fitlerTreeList = (treeList, idArr) => {
    return treeList.map( node => {
        const checked = idArr.includes(node.id);
        const disabled = node.status !== "正常" || checked;
        const newNode = {
            ...node,
            checked,
            disabled
        }
        if( newNode.children && newNode.children.length > 0){
            newNode.children = fitlerTreeList(newNode.children, idArr);
        }
        return newNode;
    });
}